﻿using System;
using System.Collections.Generic;
using System.Text;

namespace GraffitiExtras.Plugins.CommunityCredit
{
    /// <summary>
    /// Represents an exception thrown by Community Credit webservices.
    /// </summary>
    internal class CommunityCreditException : Exception
    {
        #region Properties and Fields
        private string _message = string.Empty;

        /// <summary>
        /// The message returned from the webservice.
        /// </summary>
        public override string Message
        {
            get
            {
                return this._message;
            }
        }

        #endregion

        #region Public methods

        /// <summary>
        /// Public constructor.
        /// </summary>
        /// <param name="message">String value of the message.</param>
        public CommunityCreditException(string message)
        {
            this._message = message;

            InitializeException();
        }

        #endregion

        #region Private methods

        private void InitializeException()
        {
            this.HelpLink = "http://www.community-credit.com";
        }

        #endregion
    }
}
